package com.xbongbong.pro.product.pojo;

import com.xbongbong.paas.constant.PaasConstant;
import com.xbongbong.paas.toolbox.wrap.BaseDTO;
import com.xbongbong.saas.domain.entity.ProductWarehouseEntity;
import lombok.Getter;
import lombok.Setter;

import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import java.util.Set;

/**
 * 产品关联仓库保存
 *
 * @author feng.zheng
 * @version v1.0
 * @date 2019/10/12 10:08
 * @since v1.0
 */
@Getter
@Setter
public class ProductWarehouseSavePojo extends BaseDTO {
    private Set<Long> newWarehouseIds;
    private Set<Long> oldWarehouseIds;
    private Set<Long> copyWarehouseIds;
    private List<Long> noPermissionWarehouseList;
    private List<ProductWarehouseEntity> productWarehouseEntityList;

    public ProductWarehouseSavePojo(Set<Long> newWarehouseIds) {
        this.oldWarehouseIds = new HashSet<>(PaasConstant.DEFAULT_INITIAL_CAPACITY);
        this.copyWarehouseIds = new HashSet<>(PaasConstant.DEFAULT_INITIAL_CAPACITY);
        this.noPermissionWarehouseList = new ArrayList<>();
        this.productWarehouseEntityList = new ArrayList<>();
        this.newWarehouseIds = newWarehouseIds;
    }

    public ProductWarehouseSavePojo(Set<Long> newWarehouseIds, Set<Long> oldWarehouseIds, Set<Long> copyWarehouseIds, List<Long> noPermissionWarehouseList, List<ProductWarehouseEntity> productWarehouseEntityList) {
        this.newWarehouseIds = newWarehouseIds;
        this.oldWarehouseIds = oldWarehouseIds;
        this.copyWarehouseIds = copyWarehouseIds;
        this.noPermissionWarehouseList = noPermissionWarehouseList;
        this.productWarehouseEntityList = productWarehouseEntityList;
    }


}
